<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8" />
		<title></title>
		<script src="js/jquery-1.9.1.min.js" type="text/javascript" charset="utf-8"></script>

	</head>
	<body>
		<div>
			<table>
				<tr>
					<td><img id="1" src="images/c_0.png" width="100px" height="100px" state="0"></td>
					<td><img id="2" src="images/c_0.png" width="100px" height="100px" state="0"></td>
					<td><img id="3" src="images/c_0.png" width="100px" height="100px" state="0"></td>
				</tr>
				<tr>
					<td><img id="4" src="images/c_0.png" width="100px" height="100px" state="0"></td>
					<td><img id="5" src="images/c_0.png" width="100px" height="100px" state="0"></td>
					<td><img id="6" src="images/c_0.png" width="100px" height="100px" state="0"></td>
				</tr>
				<tr>
					<td><img id="7" src="images/c_0.png" width="100px" height="100px" state="0"></td>
					<td><img id="8" src="images/c_0.png" width="100px" height="100px" state="0"></td>
					<td><img id="9" src="images/c_0.png" width="100px" height="100px" state="0"></td>
				</tr>
			</table>
		</div>

		<script>
		$(function(){
			$("img").click(function(){
				var nid=$(this).attr("id");
				var st=$(this).attr("state");
				st=Math.abs(st-1);
				
				//console.log(st);
				$(this).attr("state",st);
				if(st==0){
					//$(this).css("src":"img/c_0.png");
					$(this).attr("src","images/c_0.png")
				}
				else{
					$(this).attr("src","images/c_1.png")
				}
				
				//console.log(nid);
				
			})
		});
		
		</script>
	</body>
</html>
<!--//@ sourceMappingURL=jquery.min.map-->